<template>
  <view class="page flex-col">
    <view class="box_3 flex-col">
      <view class="image-text_3 flex-col">
        <view class="group_3 flex-col"></view>
        <text class="text-group_1">
          伏羲东方
          <br />
          数字化智慧云平台
        </text>
      </view>
      <image
          class="image_8"
          referrerpolicy="no-referrer"
          src="./imgs/welcome.png"
      />
      <view class="text-group_4 flex-col" v-if="constants">
        <text class="text_4">欢迎你，{{ constants.student.user.real_name }}同学</text>
        <text class="text_5">
          你已成功加入{{ constants.clazz.cusomer_name }}学校{{ constants.clazz.teacher_name }}老师的班级，如需加入其他老师的班级，请在“我的-我的班级”模块中继续添加。
        </text>
      </view>
      <view class="section_3 flex-col">
        <view class="text-wrapper_2 flex-col" @click="goto">
          <text class="text_6">进入平台</text>
        </view>
      </view>
    </view>
  </view>
</template>
<script>
export default {
  data() {
    return {
      constants: null,
      class_student_id: '',
    };
  },
  onLoad(){
    this.class_student_id = uni.getStorageSync('class_student_id');
    console.log('ionin')
    this.getClassInfo()
    console.log('constants',this.constants)
  },
  methods: {
    async getClassInfo(){
      console.log('ionin')
      let dataRes = await this.API.ClassStudentFetchModel({
        class_student_id: this.class_student_id,
      });
      this.constants = dataRes
      console.log('dataRes',dataRes)
    },
    goto(){
      uni.switchTab({
        url: '/pages/index/index'
      });
    },
  },
};
</script>

<style scoped lang="less">
.page {
  background-color: rgba(248, 248, 248, 1);
  position: relative;
  width: 750rpx;
  height: 100%;
  overflow: hidden;
}

.group_1 {
  background-color: rgba(255, 255, 255, 1);
  padding: 28rpx 28rpx 22rpx 42rpx;
}

.group_5 {
}

.text-wrapper_4 {
  width: 108rpx;
  height: 40rpx;
  overflow-wrap: break-word;
  font-size: 0;
  letter-spacing: -0.2800000011920929px;
  font-family: PingFangSC-Semibold;
  font-weight: 600;
  text-align: right;
  white-space: nowrap;
  line-height: 40rpx;
}

.text_9 {
  overflow-wrap: break-word;
  color: rgba(255, 255, 255, 1);
  font-size: 28rpx;
  font-family: PingFangSC-Semibold;
  font-weight: 600;
  text-align: left;
  white-space: nowrap;
  line-height: 40rpx;
}

.text_10 {
  overflow-wrap: break-word;
  color: rgba(255, 255, 255, 1);
  font-size: 28rpx;
  font-family: PingFangSC-Semibold;
  font-weight: 600;
  text-align: left;
  white-space: nowrap;
  line-height: 40rpx;
}

.thumbnail_8 {
  width: 34rpx;
  height: 22rpx;
  margin: 8rpx 0 10rpx 438rpx;
}

.thumbnail_9 {
  width: 30rpx;
  height: 22rpx;
  margin: 6rpx 0 12rpx 10rpx;
}

.image_7 {
  width: 50rpx;
  height: 24rpx;
  margin: 6rpx 0 10rpx 10rpx;
}

.group_6 {
  width: 666rpx;
  margin: 42rpx 12rpx 0 2rpx;
}

.thumbnail_10 {
  width: 40rpx;
  height: 40rpx;
  margin: 2rpx 0 10rpx 0;
}

.text_3 {
  overflow-wrap: break-word;
  color: rgba(38, 38, 38, 1);
  font-size: 36rpx;
  font-family: PingFangSC-Medium;
  font-weight: 500;
  text-align: right;
  white-space: nowrap;
  line-height: 52rpx;
}

.thumbnail_4 {
  width: 40rpx;
  height: 8rpx;
  margin: 22rpx 0 22rpx 0;
}

.box_3 {
  padding: 92rpx 0 4rpx 0;
}

.image-text_3 {
  width: 288rpx;
  align-self: center;
}

.group_3 {
  background-color: rgba(255, 255, 255, 1);
  width: 180rpx;
  height: 180rpx;
  margin: 0 56rpx 0 52rpx;
}

.text-group_1 {
  width: 288rpx;
  height: 88rpx;
  overflow-wrap: break-word;
  color: rgba(38, 38, 38, 1);
  font-size: 36rpx;
  font-family: PingFangSC-Medium;
  font-weight: 500;
  text-align: center;
  line-height: 44rpx;
  margin-top: 36rpx;
}

.image_8 {
  width: 322rpx;
  height: 266rpx;
  align-self: center;
  margin-top: 92rpx;
}

.text-group_4 {
  width: 374rpx;
  align-self: center;
  margin-top: 54rpx;
}

.text_4 {
  overflow-wrap: break-word;
  color: rgba(17, 26, 52, 1);
  font-size: 28rpx;
  font-family: PingFangSC-Medium;
  font-weight: 500;
  text-align: right;
  white-space: nowrap;
  line-height: 40rpx;
  margin: 0 62rpx 0 60rpx;
}

.text_5 {
  width: 374rpx;
  height: 128rpx;
  overflow-wrap: break-word;
  color: rgba(89, 89, 89, 1);
  font-size: 24rpx;
  font-weight: normal;
  text-align: left;
  line-height: 32rpx;
  margin-top: 24rpx;
}

.section_3 {
  background-color: rgba(255, 255, 255, 1);
  margin-top: 272rpx;
  padding: 20rpx 46rpx 18rpx 46rpx;
  position: absolute;
  bottom: 0;
}

.text-wrapper_2 {
  background-color: rgba(39, 118, 255, 1);
  border-radius: 6px;
  padding: 24rpx 262rpx 20rpx 260rpx;
}

.text_6 {
  overflow-wrap: break-word;
  color: rgba(255, 255, 255, 1);
  font-size: 34rpx;
  font-family: PingFangSC-Medium;
  font-weight: 500;
  text-align: right;
  white-space: nowrap;
  line-height: 48rpx;
}

.image_9 {
  width: 268rpx;
  height: 10rpx;
  align-self: center;
  margin-top: 72rpx;
}

</style>